#!/usr/bin/python
# -*- coding: utf-8 -*-

"""
TODO: docstring
"""

__version__ = '$Id$'

if __debug__:
    import sys
    sys.stdout.write(u'%s loading ... \n' % (__name__))
    import time
    _start_time = time.time()

import tiledtmxloader

# base64 and gziped logo
# use this to load it:
#   s_dec = gzip.GzipFile(fileobj=StringIO.StringIO(base64.b64decode(str_io)), mode='rb').read()
#   gzipper.close()
#   imgg = pygame.image.fromstring(s_dec, (32, 32), 'RGBA')
pyknic_logo_32x32 = u"""H4sIAAnMdUoC/+1XaVAUWRKmhJarORRPdMR1wxgDVwVEGuj7oGn6RkA5RCfQUcQrULxFWWdwR/FiRUFHRUBUUA5BQECBbsADZbxwVEQRb3C8R0VXOjdfdYOu7vyeP1MRX1R1Veb3vZcv38tsM7O/rj/z6m3HsPgK9gwGondvBxqWJlh9BmuGI8PK2tHKZsCw/jb2g+3pd1/YdPv1prkI55c6TIYFO9HdtQfr3EdzkjzceVs9vfkpE3iC1AkS4S4vuXA3SyPcwwoW7WWFitJZEYIM7ymqHV4xyVEjclJjx2YHZfBnkXfkG7EhtrQP+hIOwoWcLM4GDzei0a3nvXrsKFkmx7MbAQe5Pop8nkh5TKBQHxcGqStFEZoq0XRttXi2VideoNVL4jT1fsvmHuJvq4wc3fwiwtLwZJK1oSxy7K/ReYKtmnrJUmJD26KP5qQoinCokEtZLJATbqLRrSfZ6ePuv489nkC2n8OSH+EJlEV8uapUEKSuEE5RnxDNQP252hrxIo1OtCxQJ074cQs77yrb9Wm76zBoDzeHRxOt4MnIEXBJ4NqxJo1/KLDWbw2xRZ+F6DsHOaary4URyDlRcZQfID/MFciyOCyiKU7zdqP1M9kTAnK4XEUhX6YqEQQSe1q7WjQP57JYrRetjGwI3pR7c8+Zeyti3reNGQrXffpBa2gvaAliQPP4gXB/wrfweH9q58G7mXURZwOT1HrhShxDHBm/aQzhSuRGDX+iRTTFqUZ92QEOibsE467GWIWifRQ9b9TW1Irj5zVM21Navqq1KXmqoSF6BNQFmUNtEAVXJ1N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/p7Sbc5jWuByle7uJd3iy/fT586X5fqf8htso/lxMkO8IJk+VzpwYUcKcHFHJnyop50ZGbPRK3uzo0Jrv3ORuW4plA3pFvxIbYEh/i63+QrSRckn0+POT2Qo0eTV7S+DHMITbWn8GKvn9jY2v3jQ3TbpitnZ2LrT3CAeGI6GM33LYvAXMEs4/TAKshfQdaOZPn7ve0jdHWgfYlHMjFHGpj+z8aCFtna+u//gH+udd/Aar7J0sAEAAA"""


#        main = sys.modules['__main__']
#        if hasattr(main, '__file__'):
#            return os.path.dirname(main.__file__)


if __debug__:
    _dt = time.time() - _start_time
    sys.stdout.write(u'%s loaded: %fs \n' % (__name__, _dt))


